# 定义基础镜像 - sql
FROM python.algo.base-sql:1.1.1

# 安装插件
RUN pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
RUN pip install scikit-learn==1.6.1

# 设置工作目录为/Cylinder
WORKDIR /Cylinder

# 将/Cylinder的父目录加入Python路径
ENV PYTHONPATH=/

# 复制Cylinder目录内容到容器内的/Cylinder
COPY ./Cylinder .

# 设置时区
ENV TZ=Asia/Shanghai
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && \
    echo $TZ > /etc/timezone

# 运行启动脚本
CMD ["python", "run.py"]